package com.im.easy.rxeasyandroidHelper.common.net;

import com.im.easy.rxeasyandroidHelper.model.ProductItemInfo;
import com.im.easy.rxeasyandroidHelper.model.bean.welcome.WelcomeADInfo;
import com.im.easy.rxeasyandroidHelper.model.http.base.BaseResponseInfo;

import java.util.List;

import io.reactivex.Flowable;
import io.reactivex.Observable;
import retrofit2.http.GET;
import retrofit2.http.Query;

/**
 * Created by wujiajun on 17/4/5.
 */

public interface ApiService {

    String HOST = "http://192.168.2.222:8080/egg-machine/";

    @GET("api/index/goods.json")
    Flowable<BaseResponseInfo<List<ProductItemInfo>>> getProductList(@Query("page") int page,
                                                                     @Query("rows") int rows,
                                                                     @Query("type") String type);

    /**
     * 获取首页开屏广告
     * @return
     */
    @GET("api/index/welcome/ad")
    Observable<WelcomeADInfo> getWelcomeADInfo();

}
